import request from "./request";

// 市场列表
export const getMarkList = async ({
  page=1,
  size=9,
  city_id,
  search_keys,
  business_id
}) => {
  const res = await request({
    url: `/public/resources/tender/${page}`,
    method: 'get',
    data: {
      size,
      city_id,
      search_keys,
      business_id
    }
  });

  return res;
};

// 市场详情
export const getMarkDetail = async ({
  id
}) => {
  const res = await request({
    url: `/public/resources/tender/detail/${id}`,
    method: 'get'
  });

  return res;
};

// 获取市场中的城市
export const getMarkCity = async () => {
  const res = await request({
    url: '/public/resources/tender_cities',
    method: 'get'
  });

  return res;
};
